﻿using System.Windows;

namespace Leow.SelectableCanvas
{
    public class CustomSizeChangedEventArgs : RoutedEventArgs
    {
        private Size _newSize;
        private Size _oldSize;

        public CustomSizeChangedEventArgs(Size oldSize, Size newSize)
            : base(FrameworkElement.SizeChangedEvent)
        {
            _oldSize = oldSize;
            _newSize = newSize;
        }

        public double HeightDifference
        {
            get
            {
                return _newSize.Height - _oldSize.Height;
            }
        }

        public Size NewSize
        {
            get
            {
                return _newSize;
            }
        }

        public Size OldSize
        {
            get
            {
                return _oldSize;
            }
        }

        public double WidthDifference
        {
            get
            {
                return _newSize.Width - _oldSize.Width;
            }
        }
    }
}
